PYTHON-5991 - [pymongocrypt] Bundle libmongocrypt 1.20.2 - #1216
Merged
Conversation
Bump the bundled libmongocrypt version and regenerate the SBOM. The C sources in this repo already contain everything through the 1.20.2 tag, so binding.py needs no regeneration. Also correct the text_opts docstrings, which still referred to the "textPreview" algorithm. That name was removed in libmongocrypt 1.20.0 in favor of "string".
blink1073
marked this pull request as ready for review
August 14, 2026 20:05
blink1073
marked this pull request as draft
August 17, 2026 11:39
libmongocrypt asks drivers to expose these options as "string" rather than "text", so rename the parameter to match the algorithm it configures. Add tests for the deprecated spellings that libmongocrypt still accepts or rejects, so a future libmongocrypt bump cannot change either behavior silently: - the "textPreview" algorithm raises - "prefixPreview", "suffixPreview", and "substringPreview" produce payloads identical to "prefix", "suffix", and "substring" PYTHON-5959 drops the three query type aliases. Also correct the changelog, which claimed those three query types had already been replaced. They remain accepted as aliases.
The changelog now heads the release as 1.19.0, so bump __version__ to match. hatch reads the version from this file, so the built wheel carries it. The SBOM freshness check pointed at "update-sbom.sh", which does not exist. The script that regenerates the SBOM is scripts/update-version.sh.
blink1073
marked this pull request as ready for review
August 17, 2026 17:04
NoahStapp
approved these changes
Aug 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Bundles libmongocrypt 1.20.2 and renames
text_optstostring_opts. The rename is breaking, so this becomes release 1.19.0.Motivation
PYTHON-5991 asks for bundled libmongocrypt at 1.20.2 or greater. 1.20.2 adds checks when creating GCP requests.
Changes
text_optsparameter tostring_optsscripts/update-version.sh, replacing a reference to a script that does not existTesting
Standard unit tests in Evergreen.
Breaking changes
text_optsbecomesstring_optsonExplicitEncryptOptsandExplicitEncrypter.encrypt, with no alias. Keyword callers raiseTypeError; positional callers are unaffected.